package ex.com.jm.food.service.impl;

import java.util.List;

import ex.com.jm.food.dao.AdminSupTypeDao;
import ex.com.jm.food.entity.SubType;
import ex.com.jm.food.entity.SupType;
import ex.com.jm.food.service.AdminSupTypeService;

public class AdminSupTypeServiceImpl implements AdminSupTypeService {

	private AdminSupTypeDao adminSupTypeDao;
	public AdminSupTypeDao getAdminSupTypeDao() {
		return adminSupTypeDao;
	}

	public void setAdminSupTypeDao(AdminSupTypeDao adminSupTypeDao) {
		this.adminSupTypeDao = adminSupTypeDao;
	}

	@Override
	public List<SupType> getSupTypes(int initPage, int pageRow, String value) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().getSupTypes(initPage, pageRow, value);
	}

	@Override
	public int supTypeCount(String value) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().supTypeCount(value);
	}

	@Override
	public Object saveSupType(SupType supType) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().saveSupType(supType);
	}

	@Override
	public SupType checkName(String name) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().checkName(name);
	}

	@Override
	public void updateSupType(SupType supType) {
		// TODO Auto-generated method stub
      this.getAdminSupTypeDao().updateSupType(supType);
	}

	@Override
	public SupType editSupType(Integer id) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().editSupType(id);
	}

	@Override
	public void delSupType(Integer id) {
		// TODO Auto-generated method stub
       this.getAdminSupTypeDao().delSupType(id);
	}

	@Override
	public List<SubType> getSubTypes(int initPage, int pageRow, String value,
			int supId) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().getSubTypes(initPage, pageRow, value, supId);
	}

	@Override
	public int subCount(String value, int supId) {
		// TODO Auto-generated method stub
		return this.getAdminSupTypeDao().subCount(value, supId);
	}

}
